﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using DAL;
using Model;

namespace BLL
{   
    public class BTaxi
    {
        private readonly DTaxi _dTaxi = new DTaxi();


        public bool UpdateImei(string phoneNumber, string imei)
        {
            return _dTaxi.UpdateImei(phoneNumber, imei);
        }

        public bool ExistsPhoneNum(string phoneNumber)
        {
            return _dTaxi.ExistsPhoneNum(phoneNumber);
        }

        public bool Add(TaxiInfo model)
        {
            return _dTaxi.Add(model);
        }

        public bool Update(TaxiInfo model)
        {
            return _dTaxi.Update(model);
        }

        public bool UpdateState(string phoneNumber, int state)
        {
            return _dTaxi.UpdateState(phoneNumber, state);
        }
         
        public bool Delete(int id)
        {
            return _dTaxi.Delete(id);
        }

        public TaxiInfo GetModelByPhoneNum(string phoneNumber)
        {
            return _dTaxi.GetModelByPhoneNum(phoneNumber);
        }

        public DataSet GetList(string strWhere)
        {
            return _dTaxi.GetList(strWhere);
        }
    }
}
